﻿@model Lost_and_Found.Models.ViewModel.AdminModel
@{
    ViewBag.Title = "Thêm người dùng";
    Layout = "~/Views/Shared/_Backend.cshtml";
}

<div class="row">
    <h1 class="page_title" style="float: left;">Thêm người dùng</h1>
</div>

@using (Html.BeginForm("NewUser", "Administrator", FormMethod.Post))
{
    <fieldset>
        <legend></legend>
        <div id="RegisterForm" class="create_user">

            <div class="row">
                <label class="label_heading" for="Username">Tên đăng nhập</label>
                @Html.TextBoxFor(m => m.Username)
                @Html.ValidationMessageFor(m => m.Username, "", new { @class = "ValidationMessage" })
                <div class="clearfix"></div>
            </div>

            <div class="row">
                <label class="label_heading" for="Fullname">Tên đầy đủ</label>
                @Html.TextBoxFor(m => m.Fullname)
                @Html.ValidationMessageFor(m => m.Fullname, "", new { @class = "ValidationMessage" })
                <div class="clearfix"></div>
            </div>

            <div class="row">
                <label class="label_heading" for="Email">Email</label>
                @Html.TextBoxFor(m => m.Email)
                @Html.ValidationMessageFor(m => m.Email, "", new { @class = "ValidationMessage" })
                <div class="clearfix"></div>
            </div>

            <div class="row">
                <label class="label_heading" for="Password">Mật khẩu</label>
                @Html.PasswordFor(m => m.Password)
                @Html.ValidationMessageFor(m => m.Password, "", new { @class = "ValidationMessage" })
                <div class="clearfix"></div>
            </div>

            <div class="row">
                <label class="label_heading" for="ComfirmPassword">Xác nhận mật khẩu</label>
                @Html.PasswordFor(m => m.ComfirmPassword)
                @Html.ValidationMessageFor(m => m.ComfirmPassword, "", new { @class = "ValidationMessage" })
                <div class="clearfix"></div>
            </div>
            <div class="row">
                <label class="label_heading" for="Role">Quyền</label>
                @Html.DropDownListFor(m => m.Role, new SelectList(new[] { "Admin", "Member" }))
                <div class="clearfix"></div>
            </div>
        </div>
        <div style="color: red;">
            @Html.ValidationSummary(true)
        </div>
        <input class="btn btn-success" value="Thêm" type="submit">
    </fieldset>

}
